package com.xjc.business.service;

import com.xjc.business.entity.domain.ActivityJoinLists;
import com.baomidou.mybatisplus.extension.service.IService;
import com.xjc.business.entity.po.stu.ActivityJoinPo;
import com.xjc.business.entity.vo.stu.ActivityCurrentJoinVo;
import com.xjc.business.entity.vo.stu.ActivityJoinVo;
import com.xjc.business.entity.vo.ActivityRankVo;
import com.xjc.system.result.Result;
import org.springframework.web.bind.annotation.GetMapping;

import java.util.List;

/**
* @author root
* @description 针对表【activity_join_lists(宿舍评优活动参加表)】的数据库操作Service
* @createDate 2025-01-25 10:24:30
*/
public interface ActivityJoinListsService extends IService<ActivityJoinLists> {

    /**
     * 获取宿舍评优活动参与列表-学生端
     * @param id 宿舍评优id
     * @return Result
     */
    @GetMapping("/joinList/{id}")
    Result<List<ActivityJoinVo>> getActivityJoinListAtStu(Integer id);

    /**
     * 获取宿舍评优活动排名列表-前十
     * @param id 宿舍评优id
     * @return Result
     */
    Result<List<ActivityRankVo>> getActivityRankList(Integer id);

    /**
     * 参加宿舍评优活动
     * @param activityJoinPo 信息
     * @return Result
     */
    Result<String> joinActivity(ActivityJoinPo activityJoinPo);

    /**
     * 判断是否已经参加
     * @param activityId 宿舍评优活动id
     * @param wxId 微信id
     * @return Result
     */
    Result<Boolean> hasJoined(Integer activityId, Integer wxId);

    /**
     * 获取当前参加信息
     * @param activityId 宿舍评优活动id
     * @param wxId 微信id
     * @return Result
     */
    Result<ActivityCurrentJoinVo> getCurrentJoinInfo(Integer activityId, Integer wxId);
}
